﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace TagLib
{
    public class PictureData : IPicture
    {
        private ByteVector bv;
        private string description = string.Empty;
        private PictureType pt = PictureType.FrontCover;
        private string mime = "image/jpeg";
        private IPicture source;

        public PictureData(byte[] newImage) : this(null, newImage) { }
        public PictureData(IPicture sourcePicture, byte[] newImage)
        {
            this.bv = new ByteVector(newImage, newImage.Length);
            this.source = sourcePicture;
        }

        public ByteVector Data
        {
            get
            {
                return bv;
            }
            set
            {
                throw new NotImplementedException();
            }
        }

        public string Description
        {
            get
            {
                if (source != null)
                    return source.Description;
                return description;
            }
            set
            {
                throw new NotImplementedException();
            }
        }

        public string MimeType
        {
            get
            {
                return mime;
            }
            set
            {
                throw new NotImplementedException();
            }
        }

        public PictureType Type
        {
            get
            {
                return pt;
            }
            set
            {
                throw new NotImplementedException();
            }
        }
    }
}
